package com.itheima.homework;

public class Demo1 {
    public static void main(String[] args) {
        int[] arr = {11, 22, 33};
        getArray(arr);
    }

    public static void getArray(int[] arr) {
        System.out.print("[");
        int count = 0;
        for (int i = 0; i < arr.length; i++) {
            count++;

            if (count == arr.length) {
                System.out.print(arr[i] + "]");
                break;
            }
            System.out.print(arr[i] + ",");

        }


    }
}